let array1=[1,2,3];
let array2=[4,5,6];
let newArray=[...array1,...array2];
console.log(newArray);